package com.example.jasonrpc.proto;

/**
 * 表示rpc的返回
 */
public class Response {
    /**
     * 0-成功，非0-失败
     */
    private int code = 0;
    /**
     * 错误信息
     */
    private String message = "OK";
    private Object data;

    public Response() {
    }

    public Response(int code, String message, Object data) {
        this.code = code;
        this.message = message;
        this.data = data;
    }

    public int getCode() {
        return code;
    }

    public void setCode(int code) {
        this.code = code;
    }

    public String getMessage() {
        return message;
    }

    public void setMessage(String message) {
        this.message = message;
    }

    public Object getData() {
        return data;
    }

    public void setData(Object data) {
        this.data = data;
    }
}
